Skip to content

fix(@angular/build): show unit-test error for missing vitest browser package #30293

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 13, 2025

Conversation

clydin
Copy link
Member

@clydin clydin commented May 12, 2025

When using the experimental unit-test builder with the vitest runner and the browsers option, an error will now be reported if the @vitest/browser package is not found. Previously, the tests would attempt to execute and produce a runtime error and stack trace. Now an explicit error with instructions to install the package will be printed to the console prior to building and executing the tests.

…package

When using the experimental `unit-test` builder with the `vitest` runner
and the `browsers` option, an error will now be reported if the `@vitest/browser`
package is not found. Previously, the tests would attempt to execute and
produce a runtime error and stack trace. Now an explicit error with instructions
to install the package will be printed to the console prior to building
and executing the tests.
@clydin clydin added the target: rc This PR is targeted for the next release-candidate label May 12, 2025
@clydin clydin added the action: review The PR is still awaiting reviews from at least one requested reviewer label May 12, 2025
@clydin clydin requested a review from alan-agius4 May 12, 2025 18:39
@alan-agius4 alan-agius4 added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels May 13, 2025
@clydin clydin merged commit 9a50040 into angular:main May 13, 2025
57 of 58 checks passed
@clydin
Copy link
Member Author

clydin commented May 13, 2025

The changes were merged into the following branches: main, 20.0.x

@clydin clydin deleted the unit-test/vitest-browser-error branch May 13, 2025 10:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
action: merge The PR is ready for merge by the caretaker area: @angular/build target: rc This PR is targeted for the next release-candidate
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants